package com.dao.lx;

import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;

import com.entity.Qa;
public interface QaDAO extends JpaRepository<Qa, Long> {
	@Query("from Qa q where q.qaClassify like ?1 and q.qaIfdelete = 1")
	public Page<Qa> queryByQaClassify(String qaClassify, Pageable p);
	
	@Query("from Qa q where q.qaQuestion like ?1 and q.qaIfdelete = 1")
	public Page<Qa> queryByQaQuestion(String qaQuestion, Pageable p);

	@Query("from Qa q where q.qaIfdelete = 1")
	public Page<Qa> findAllQaIfdelete1(Pageable p);
}
